
#include "stdafx.h"
#include "AKCommon.h"

#include "UnitTest++.h"

#include "AKCPPTTTPlayer.h"

namespace {

struct CPlayerFixture
{
	CPlayerFixture() : _side(0), _numOfSides(2)
	{};

	AKSideIndex _side;
	unsigned int _numOfSides;
};

TEST_FIXTURE(CPlayerFixture, ConstructorTest)
{
	AKCPPTTTPlayer player(_side, _numOfSides);
	player.backToInitialState();

	AKMove newMove = player.getBestMove();
	CHECK(newMove.side == _side);
	CHECK(newMove.dstCell >= 0 && newMove.dstCell < 9);
	CHECK(newMove.piece == 0); // only one kind of piece
	
	CHECK(true);
}

} // namespace